cmake_minimum_required(VERSION 3.22)

project(main)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# add_subdirectory("./Buffer")
add_subdirectory("./AsyncLogger")

file(GLOB SRCS "*.cpp")

foreach(cppfile IN LISTS SRCS)
    message(STATUS "add ${cppfile} to ${PROJECT_NAME}")
endforeach()

add_executable(main ${SRCS})

target_include_directories(main 
PRIVATE
    ${CMAKE_CURRENT_SOURCE_DIR}/
    ${AsyncLogger_SOURCE_DIR}/
)

target_link_libraries(main
PRIVATE
    AsyncLogger-static
)